package kadledav.adventure.framework.controll.commands;

import java.io.PrintStream;
import java.util.Scanner;

import kadledav.adventure.framework.controll.ControllConstants;
import kadledav.adventure.framework.controll.commands.abstr.CommandAbstract;
import kadledav.adventure.framework.model.world.Player;

public class HelpCommand extends CommandAbstract {

	public HelpCommand(PrintStream out, Scanner in, Player player) {
		super(out, in, player);
	}

	@Override
	public void execute(String[] userCommand) {
		out.println("Prikazy a parametry se oddeluji mezerami.");
		out.println("Seznam prikazu, kterymi muzete ovladat tuto hru:");
		out.println();
		printCommandInfo(ControllConstants.EXPLORE_LOCATION, "Porozhledne se po lokaci");
		printCommandInfo(ControllConstants.SHOW_INVENTORY, "Ukaze obsah inventare");
		printCommandInfo(ControllConstants.GO_LOCATION, "Zkusi projit pruchodem poslanym v parametru");
		printCommandInfo(ControllConstants.TAKE_ITEM, "Vezme predmet ktery je v mistnosti");
		printCommandInfo(ControllConstants.DROP_ITEM, "Odlozi predmet v mistnosti");
		printCommandInfo(ControllConstants.USE, "Pouzije objekt, predany v parametru. Je mozne predat az dva objekty pro vzajemnou interakci");
		printCommandInfo(ControllConstants.EXIT, "Ukonci hru");
		printCommandInfo(ControllConstants.HELP, "Vyvola tuto napovedu");
		out.println();
	}

	private void printCommandInfo(String commandName,String commandDescription ){
		out.println(commandName+" - "+commandDescription);
	}

}
